<!--包含头部文件-->
{include file="public/_meta" /}
<title>推荐位列表</title>
</head>
<body>
<nav class="breadcrumb"></nav>
<div class="page-container">
    <div class="text-c">
        <form method="get" action="{:url('featured/index')}">
            <label class="form-label col-xs-4 col-sm-2"><span class="c-red">*</span>选择推荐类别：</label>
            <div class="formControls col-xs-8 col-sm-3"> <span class="select-box">
        <select name="type" class="select">

          {volist name="types" id="vo"}
          <option value="{$key}" {if condition="$key eq $type"} selected {/if}}>{$vo}</option>
          {/volist}

        </select>
        </span>
            </div>

            <button name="" id="" class="btn btn-success" type="submit"><i class="Hui-iconfont"></i> 搜索</button>
        </form>
    </div>

    <div class="mt-20">
        <table class="table table-border table-bordered table-bg table-hover table-sort">
            <thead>
            <tr class="text-c">
                <th width="40">ID</th>
                <th width="150">标题</th>
                <th width="100">地址</th>
                <th width="150">新增时间</th>
                <th width="30">发布状态</th>
                <th width="30">操作</th>
            </tr>
            </thead>
            <tbody>
            {volist name="results" id="vo"}
            <tr class="text-c">
                <td>{$vo.id}</td>
                <td><a href="{$vo.url}" target="_blank">{$vo.title}</a></td>
                <td class="text-c">{$vo.url}</td>
                <td>{$vo.create_time}</td>
                <td class="td-status">{$vo.status|getStatus}</td>
                <td class="td-manage">
                    {if condition="$vo.status eq 1"}
                    <a style="text-decoration:none" onClick="picture_stop(this,'{$vo.id}')" href="javascript:;" title="下架"><i class="Hui-iconfont">&#xe6de;</i></a>
                    {else}
                    <a style="text-decoration:none" onClick="picture_start(this,'{$vo.id}')" href="javascript:;" title="发布"><i class="Hui-iconfont">&#xe603;</i></a>
                    {/if}
                    <a style="text-decoration:none" class="ml-5" onClick="picture_edit('编辑','{:url('featured/edit',['id'=>$vo.id])}','10001')" href="javascript:;" title="编辑"><i class="Hui-iconfont">&#xe6df;</i></a>
                    <a style="text-decoration:none" class="ml-5" onClick="picture_del(this,'{$vo.id}')" href="javascript:;" title="删除"><i class="Hui-iconfont">&#xe6e2;</i></a>
                </td>
            </tr>
            {/volist}

            </tbody>
        </table>
    </div>
    {:pagination($results)}
</div>

<!--_footer 作为公共模版分离出去-->
{include file="public/_footer"}
<!--/_footer 作为公共模版分离出去-->

<!--请在下方写此页面业务相关的脚本-->
<!--<script type="text/javascript" src="lib/datatables/1.10.0/jquery.dataTables.min.js"></script>-->
<!--<script type="text/javascript" src="lib/laypage/1.2/laypage.js"></script>-->
<script type="text/javascript" src="__STATIC__/admin/js/common.js"></script>
<script type="text/javascript">
    var SCOPE = {
        "status_url":"{:url('featured/status')}"
    };

</script>
</body>
</html>